/**
 * Copyright (c) 2024-2025 National Fundamental Software of China Co., Ltd.
 *
 * You should have find a copy of NFSChina License. If not, please contact us
 * by email <os_support@nfschina>
 *
**/

/*
import QtQuick 2.15
import QtQuick.Layouts 1.15
import QtQuick.Templates 2.15 as T
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 3.0 as PC3
import org.kde.plasma.private.kicker 0.1 as Kicker


BasePage {
    id: root
    property int appsModelRow: 0
    property Kicker.AppsModel appsModel: plasmoid.rootItem.rootModel.modelForRow(appsModelRow)

    contentAreaComponent: KickoffListView {
        id: catogoriesView
        focus: true // needed for Loaders
        model: plasmoid.rootItem.rootModel
        // needed otherwise app displayed at top-level will show a first character as group.
        section.property: ""


        delegate: KickoffListDelegate {
            width: view.availableWidth
            isCategoryListItem: true
        }
    }
}
*/

import QtQuick 2.15
import QtQuick.Layouts 1.15
import QtQuick.Templates 2.15 as T
import QtQml 2.15
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 3.0 as PC3
import org.kde.plasma.private.kicker 0.1 as Kicker

BasePage {
    id: root

    contentAreaComponent: VerticalStackView {
        id: stackView
        popEnter: Transition {
            NumberAnimation {
                property: "x"
                from: 0.5 * root.width
                to: 0
                duration: PlasmaCore.Units.longDuration
                easing.type: Easing.OutCubic
            }
            NumberAnimation {
                property: "opacity"
                from: 0.0
                to: 1.0
                duration: PlasmaCore.Units.longDuration
                easing.type: Easing.OutCubic
            }
        }

        pushEnter: Transition {
            NumberAnimation {
                property: "x"
                from: 0.5 * -root.width
                to: 0
                duration: PlasmaCore.Units.longDuration
                easing.type: Easing.OutCubic
            }
            NumberAnimation {
                property: "opacity"
                from: 0.0
                to: 1.0
                duration: PlasmaCore.Units.longDuration
                easing.type: Easing.OutCubic
            }
        }

        focus: true
        initialItem: categoriesViewComponent

        Component {
            id: categoriesViewComponent
            KickoffCategoryListView {
                focus: true // needed for Loaders
                mainContentView: true
                model: plasmoid.rootItem.rootModel
                // needed otherwise app displayed at top-level will show a first character as group.
                section.property: ""

            }
        }
    }

}
